<template>
  <Empty
    class="v-empty"
    :image="Empty.PRESENTED_IMAGE_SIMPLE"
    :description="description"
    :imageStyle="imageStyle"
  />
</template>

<script>
import { Empty } from "ant-design-vue";

export default {
  components: {
    Empty
  },
  props: {
    description: {
      type: String,
      default: "暂无数据"
    },
    size: {
      type: String,
      default: "medium"
    }
  },
  computed: {
    imageStyle() {
      if (this.size === "large") {
        return {};
      }

      return {};
    }
  },
  data() {
    return {
      Empty
    };
  }
};
</script>

<style lang="less" scoped>
.v-empty {
  margin: 80px auto;
}
</style>
